

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>The argument module &mdash; pyamp v1.2 documentation</title>
    <link rel="stylesheet" href="../_static/default.css" type="text/css" />
    <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../',
        VERSION:     '1.2',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="../_static/jquery.js"></script>
    <script type="text/javascript" src="../_static/underscore.js"></script>
    <script type="text/javascript" src="../_static/doctools.js"></script>
    <link rel="top" title="pyamp v1.2 documentation" href="../index.html" />
    <link rel="up" title="The http module" href="mod_pyamp_web_http.html" />
    <link rel="next" title="The hacking module" href="pyamp_web_hacking.html" />
    <link rel="prev" title="The constants module" href="pyamp_web_http_constants.html" /> 
  </head>
  <body>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="../genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="../py-modindex.html" title="Python Module Index"
             >modules</a> |</li>
        <li class="right" >
          <a href="pyamp_web_hacking.html" title="The hacking module"
             accesskey="N">next</a> |</li>
        <li class="right" >
          <a href="pyamp_web_http_constants.html" title="The constants module"
             accesskey="P">previous</a> |</li>
        <li><a href="../index.html">pyamp v1.2 documentation</a> &raquo;</li>
          <li><a href="mod_pyamp.html" >The pyamp module</a> &raquo;</li>
          <li><a href="mod_pyamp_web.html" >The web module</a> &raquo;</li>
          <li><a href="mod_pyamp_web_http.html" accesskey="U">The http module</a> &raquo;</li> 
      </ul>
    </div>  

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="module-pyamp.web.http.argument">
<span id="the-argument-module"></span><h1>The argument module<a class="headerlink" href="#module-pyamp.web.http.argument" title="Permalink to this headline">¶</a></h1>
<p>The argument module contains the Argument class which provides
the ability to create and manage arguments that can be passed
through HTTP requests.</p>
<div class="section" id="the-boolargument-class">
<h2>The BoolArgument class<a class="headerlink" href="#the-boolargument-class" title="Permalink to this headline">¶</a></h2>
<p class="graphviz">
<img src="../_images/inheritance-b3c8ff3942bb18e14847279e24e5146df23ac22b.png" alt="Inheritance diagram of pyamp.web.http.argument.BoolArgument" usemap="#inheritance2970c7094c" class="inheritance"/>
<map id="inheritance2970c7094c" name="inheritance2970c7094c">
<area shape="rect" href="#pyamp.web.http.argument.Argument" title="pyamp.web.http.argument.Argument" alt="" coords="20,7,279,33"/>
<area shape="rect" href="#pyamp.web.http.argument.BoolArgument" title="pyamp.web.http.argument.BoolArgument" alt="" coords="5,84,293,111"/>
</map>
</p>
<dl class="class">
<dt id="pyamp.web.http.argument.BoolArgument">
<em class="property">class </em><tt class="descclassname">pyamp.web.http.argument.</tt><tt class="descname">BoolArgument</tt><big>(</big><em>required=False</em>, <em>default=None</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#BoolArgument"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.BoolArgument" title="Permalink to this definition">¶</a></dt>
<dd><p>The BoolArgument class provides a class to easily create
an boolean argument.</p>
<ul class="simple">
<li>required &#8211; True if the argument is required, False otherwise</li>
<li>default &#8211; The default value for optional Arguments</li>
</ul>
</dd></dl>

</div>
<div class="section" id="the-floatargument-class">
<h2>The FloatArgument class<a class="headerlink" href="#the-floatargument-class" title="Permalink to this headline">¶</a></h2>
<p class="graphviz">
<img src="../_images/inheritance-36610831f571caedb8374073b4fadfeb5366b1e2.png" alt="Inheritance diagram of pyamp.web.http.argument.FloatArgument" usemap="#inheritance8ede968331" class="inheritance"/>
<map id="inheritance8ede968331" name="inheritance8ede968331">
<area shape="rect" href="#pyamp.web.http.argument.Argument" title="pyamp.web.http.argument.Argument" alt="" coords="21,7,280,33"/>
<area shape="rect" href="#pyamp.web.http.argument.FloatArgument" title="pyamp.web.http.argument.FloatArgument" alt="" coords="5,84,296,111"/>
</map>
</p>
<dl class="class">
<dt id="pyamp.web.http.argument.FloatArgument">
<em class="property">class </em><tt class="descclassname">pyamp.web.http.argument.</tt><tt class="descname">FloatArgument</tt><big>(</big><em>required=False</em>, <em>default=None</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#FloatArgument"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.FloatArgument" title="Permalink to this definition">¶</a></dt>
<dd><p>The FloatArgument class provides a class to easily create
an float argument.</p>
<ul class="simple">
<li>required &#8211; True if the argument is required, False otherwise</li>
<li>default &#8211; The default value for optional Arguments</li>
</ul>
</dd></dl>

</div>
<div class="section" id="the-strargument-class">
<h2>The StrArgument class<a class="headerlink" href="#the-strargument-class" title="Permalink to this headline">¶</a></h2>
<p class="graphviz">
<img src="../_images/inheritance-7507b52e5d3e1dbb39a9d9a3c37c2b762a7b2a01.png" alt="Inheritance diagram of pyamp.web.http.argument.StrArgument" usemap="#inheritancee795706c43" class="inheritance"/>
<map id="inheritancee795706c43" name="inheritancee795706c43">
<area shape="rect" href="#pyamp.web.http.argument.Argument" title="pyamp.web.http.argument.Argument" alt="" coords="15,7,273,33"/>
<area shape="rect" href="#pyamp.web.http.argument.StrArgument" title="pyamp.web.http.argument.StrArgument" alt="" coords="5,84,283,111"/>
</map>
</p>
<dl class="class">
<dt id="pyamp.web.http.argument.StrArgument">
<em class="property">class </em><tt class="descclassname">pyamp.web.http.argument.</tt><tt class="descname">StrArgument</tt><big>(</big><em>required=False</em>, <em>default=None</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#StrArgument"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.StrArgument" title="Permalink to this definition">¶</a></dt>
<dd><p>The StrArgument class provides a class to easily create
a string argument.</p>
<ul class="simple">
<li>required &#8211; True if the argument is required, False otherwise</li>
<li>default &#8211; The default value for optional Arguments</li>
</ul>
</dd></dl>

</div>
<div class="section" id="the-argument-class">
<h2>The Argument class<a class="headerlink" href="#the-argument-class" title="Permalink to this headline">¶</a></h2>
<p class="graphviz">
<img src="../_images/inheritance-e8d6e8ec7082789b23d5de5e3e51e0de0b5db531.png" alt="Inheritance diagram of pyamp.web.http.argument.Argument" usemap="#inheritanceec4a209f30" class="inheritance"/>
<map id="inheritanceec4a209f30" name="inheritanceec4a209f30">
<area shape="rect" href="#pyamp.web.http.argument.Argument" title="pyamp.web.http.argument.Argument" alt="" coords="5,7,264,33"/>
</map>
</p>
<dl class="class">
<dt id="pyamp.web.http.argument.Argument">
<em class="property">class </em><tt class="descclassname">pyamp.web.http.argument.</tt><tt class="descname">Argument</tt><big>(</big><em>argumentType</em>, <em>required=False</em>, <em>default=None</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#Argument"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.Argument" title="Permalink to this definition">¶</a></dt>
<dd><p>The Argument class encapsulates the concept of an HTTP argument
passed through a URL request.</p>
<p>Arguments can have a specific type, can be required or optional,
and can have a default value if they are optional and not passed in
the request.</p>
<ul class="simple">
<li>argumentType &#8211; The type of the argument</li>
<li>required &#8211; True if the argument is required, False otherwise</li>
<li>default &#8211; The default value for optional Arguments</li>
</ul>
<dl class="method">
<dt id="pyamp.web.http.argument.Argument.convertValue">
<tt class="descname">convertValue</tt><big>(</big><em>value</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#Argument.convertValue"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.Argument.convertValue" title="Permalink to this definition">¶</a></dt>
<dd><p>Convert the given value to the expected type of the Argument.</p>
<ul class="simple">
<li>value &#8211; The value of the argument passed in the request</li>
</ul>
</dd></dl>

<dl class="method">
<dt id="pyamp.web.http.argument.Argument.getDefaultValue">
<tt class="descname">getDefaultValue</tt><big>(</big><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#Argument.getDefaultValue"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.Argument.getDefaultValue" title="Permalink to this definition">¶</a></dt>
<dd><p>Return the default value for this Argument.</p>
</dd></dl>

<dl class="method">
<dt id="pyamp.web.http.argument.Argument.isRequired">
<tt class="descname">isRequired</tt><big>(</big><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#Argument.isRequired"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.Argument.isRequired" title="Permalink to this definition">¶</a></dt>
<dd><p>Determine if this is a required Argument or an optional Argument.</p>
</dd></dl>

</dd></dl>

</div>
<div class="section" id="the-intargument-class">
<h2>The IntArgument class<a class="headerlink" href="#the-intargument-class" title="Permalink to this headline">¶</a></h2>
<p class="graphviz">
<img src="../_images/inheritance-ee7d7acf5ede814122e0f19076c4142eea4671ee.png" alt="Inheritance diagram of pyamp.web.http.argument.IntArgument" usemap="#inheritance1ee57b8582" class="inheritance"/>
<map id="inheritance1ee57b8582" name="inheritance1ee57b8582">
<area shape="rect" href="#pyamp.web.http.argument.Argument" title="pyamp.web.http.argument.Argument" alt="" coords="13,7,272,33"/>
<area shape="rect" href="#pyamp.web.http.argument.IntArgument" title="pyamp.web.http.argument.IntArgument" alt="" coords="5,84,280,111"/>
</map>
</p>
<dl class="class">
<dt id="pyamp.web.http.argument.IntArgument">
<em class="property">class </em><tt class="descclassname">pyamp.web.http.argument.</tt><tt class="descname">IntArgument</tt><big>(</big><em>required=False</em>, <em>default=None</em><big>)</big><a class="reference internal" href="../_modules/pyamp/web/http/argument.html#IntArgument"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pyamp.web.http.argument.IntArgument" title="Permalink to this definition">¶</a></dt>
<dd><p>The IntArgument class provides a class to easily create
an integer argument.</p>
<ul class="simple">
<li>required &#8211; True if the argument is required, False otherwise</li>
<li>default &#8211; The default value for optional Arguments</li>
</ul>
</dd></dl>

</div>
</div>


          </div>
        </div>
      </div>
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h3><a href="../index.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">The argument module</a><ul>
<li><a class="reference internal" href="#the-boolargument-class">The BoolArgument class</a></li>
<li><a class="reference internal" href="#the-floatargument-class">The FloatArgument class</a></li>
<li><a class="reference internal" href="#the-strargument-class">The StrArgument class</a></li>
<li><a class="reference internal" href="#the-argument-class">The Argument class</a></li>
<li><a class="reference internal" href="#the-intargument-class">The IntArgument class</a></li>
</ul>
</li>
</ul>

  <h4>Previous topic</h4>
  <p class="topless"><a href="pyamp_web_http_constants.html"
                        title="previous chapter">The constants module</a></p>
  <h4>Next topic</h4>
  <p class="topless"><a href="pyamp_web_hacking.html"
                        title="next chapter">The hacking module</a></p>
  <h3>This Page</h3>
  <ul class="this-page-menu">
    <li><a href="../_sources/_generated/pyamp_web_http_argument.txt"
           rel="nofollow">Show Source</a></li>
  </ul>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" size="18" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="../genindex.html" title="General Index"
             >index</a></li>
        <li class="right" >
          <a href="../py-modindex.html" title="Python Module Index"
             >modules</a> |</li>
        <li class="right" >
          <a href="pyamp_web_hacking.html" title="The hacking module"
             >next</a> |</li>
        <li class="right" >
          <a href="pyamp_web_http_constants.html" title="The constants module"
             >previous</a> |</li>
        <li><a href="../index.html">pyamp v1.2 documentation</a> &raquo;</li>
          <li><a href="mod_pyamp.html" >The pyamp module</a> &raquo;</li>
          <li><a href="mod_pyamp_web.html" >The web module</a> &raquo;</li>
          <li><a href="mod_pyamp_web_http.html" >The http module</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
        &copy; Copyright 2012, Brett Ponsler.
      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.0.1.
    </div>
  </body>
</html>